package com.cloud.admin.api.service;

import com.cloud.core.db.entity.ConfigAdEntity;
import com.cloud.core.db.mapper.ConfigAdMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import java.sql.SQLException;
import java.util.List;

/**
 * Created by cloudy.xie on 17/12/14.
 */
@Component
public class ApiService {
    @Autowired
    private ConfigAdMapper configAdMapper;

    public List<ConfigAdEntity> getCurrentAds() throws SQLException {
        return configAdMapper.selectByExample(new ConfigAdEntity());
    }
}
